package com.linwen.javase.genericParadigm;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.Getter;
import lombok.NoArgsConstructor;

/**
 * lombok注解给实体类瘦身
 * @author : linwen
 * @date : 下午10:39 2021/8/11
 */
@Data
public class Circle {
    private int r;
    private int d;
    private double round;
    private double area;

    public Circle(int r){
        this.r = r;
        this.d = 2*r;
        this.round = d*Math.PI;
        this.area = r*r*Math.PI;
    }

}
